package com.yxlgateway.gateway.controller;

import com.yxlcommon.common.pojo.OrderItem;
import com.yxlcommon.common.pojo.RespBean;
import com.yxlgateway.service.OrderItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author: yxl
 * @since: 2022-01-15
 **/
@RestController
@RequestMapping("/orderItem")
public class OrderItemController {

    @Autowired
    private OrderItemService orderItemService;

    @PostMapping("/getOrderItemByOrderNum")
    public RespBean getOrderItemByOrderNum(@RequestBody OrderItem orderItem){
        return orderItemService.searchOrderItemByOrderNum(orderItem.getOrderNum());
    }
}
